import request from '@/utils/request'

export function getAll(param) {
  return request({
    url: '/produceOrderProductPlan/GetAll',
    method: 'get',
    params: param
  })
}
export function getList(param) {
    return request({
      url: '/produceOrderProductPlan/list',
      method: 'get',
      params: param
    })
  }

export function getOne(param) {
  return request({
    url: '/produceOrderProductPlan/Get',
    method: 'get',
    params: param
  })
}

export function create(param) {
  return request({
    url: '/produceOrderProductPlan/save',
    method: 'post',
    data: param
  })
}

export function update(param) {
  return request({
    url: '/produceOrderProductPlan/save',
    method: 'post',
    data:param
  })
}
export function deleteBatch(param) {
  let url ='/produceOrderProductPlan/deleteBatch'
  return request({
    url: url,
    method: 'delete',
    data: param
  })
}
export function getUnSceduledProduceLines(param) {
  let url ='/produceOrderProductPlan/getUnSceduledProduceLines'
  return request({
    url: url,
    method: 'get',
    params: param
  })
}
export function sceduledProduceLine(param) {
  let url ='/produceOrderProductPlan/sceduledProduceLine'
  return request({
    url: url,
    method: 'post',
    data: param
  })
}

export function getUnReverseSceduledProduceLines(param) {
  let url ='/produceOrderProductPlan/getUnReverseSceduledProduceLines'
  return request({
    url: url,
    method: 'get',
    params: param
  })
}

export function getProcedures(param) {
  let url ='/produceOrderProductPlan/getProcedures'
  return request({
    url: url,
    method: 'get',
    params: param
  })
}

export function getBottleneckProcedure(param) {
  return request({
    url: '/produceOrderProductPlan/getBottleneckProcedure',
    method: 'post',
    data: param
  })
}

export function getMonthGanttTask(param) {
  return request({
    url: '/produceOrderProductPlan/getMonthGanttTask',
    method: 'post',
    data: param
  })
}
export function getRequiredMaterial(param) {
  return request({
    url: '/produceOrderProductPlan/getRequiredMaterial',
    method: 'get',
    params: param
  })
}

export function getSceduledProduceLines(param) {
  let url ='/produceOrderProductPlan/getSceduledProduceLines'
  return request({
    url: url,
    method: 'get',
    params: param
  })
}

export function getScheduledProduceOrderProductPlans(param) {
  let url ='/produceOrderProductPlan/getScheduledProduceOrderProductPlans'
  return request({
    url: url,
    method: 'get',
    params: param
  })
}




